package cn.aitrox.ry.service.auth.mapper;

import cn.aitrox.ry.service.auth.entity.AuthGroupUserEntity;
import com.github.abel533.mapper.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface AuthGroupUserMapper extends Mapper<AuthGroupUserEntity> {

    void deleteByGroupId(@Param("groupId") Integer groupId);

    void batchInsert(@Param("list") List<AuthGroupUserEntity> list);

    void deleteByGroupIdUserIds(@Param("groupId") Integer groupId, @Param("userIds") List<Integer> userIds);

    List<AuthGroupUserEntity> findByUserIds(@Param("userIds") List<Integer> userIds);

    List<AuthGroupUserEntity> findByGroupIds(@Param("groupIds") List<Integer> groupIds);
}
